package xuanke2;

public class xuan {
	public static void main(String[] args) {
		lesson gdss=new lesson(001,"高等数学","教101","周一8：00-9：40");
		lesson dxwl=new lesson(002,"大学物理","教102","周二8：00-9：40");
		
		teacher zhang=new teacher(0001,"张老师","男",new lesson[]{gdss});
		teacher li=new teacher(0002,"李老师","男",new lesson[]{dxwl});
		
		gdss.setTeacher(zhang);
		dxwl.setTeacher(li);
		
		student zhao=new student(2021001,"赵同学","男",new lesson[1]);
		student liu=new student(2021002,"刘同学","女",new lesson[1]);
		
		zhao.xuanke(gdss);
		liu.xuanke(dxwl);
		liu.tuike(dxwl);
		
		System.out.println("学生编号:"+zhao.id+
	            "\n学生姓名:"+zhao.name+
	            "\n学生性别:"+zhao.gender);

		System.out.println("课程编号:"+zhao.lesson1[0].id+"\t课程名称:"+zhao.lesson1[0].name+"\t上课时间:"
	            +zhao.lesson1[0].time+"\t上课地点:"+zhao.lesson1[0].place+"\t教师:"+zhao.lesson1[0].teacher1.name);

		
		System.out.println("学生编号:"+liu.id+
	            "\n学生姓名:"+liu.name+
	            "\n学生性别:"+liu.gender);
		
		System.out.println("课程编号:"+liu.lesson1[0].id+"\t课程名称:"+liu.lesson1[0].name+"\t上课时间:"
	            +liu.lesson1[0].time+"\t上课地点:"+liu.lesson1[0].place+"\t教师:"+liu.lesson1[0].teacher1.name);
		
	}
	
}